<?php
/**
 * Created by 项目.
 * User: xuguopeng
 * Date: 2020-06-16
 * Time: 17:13
 */

namespace app\api\model;


class User extends BaseModel
{
    protected $hidden = [
        'openid', 'update_time', 'delete_time'
    ];
    // 性别
    public function getGenderAttr($value)
    {
        if($value == 1) {
            return '男';
        } elseif($value == 2) {
            return '女';
        } else {
            return '保密';
        }
    }
}